package com.lancoo.ccas52.mapper;
import com.lancoo.ccas52.entity.PlanTeaching;
import org.apache.ibatis.annotations.Param;
import java.util.Collection;
import java.util.List;

import com.lancoo.ccas52.entity.PlanTeachingStudent;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.lancoo.ccas52.config.MybatisRedisCache;
import org.apache.ibatis.annotations.CacheNamespace;

/**
 * <p>
 * 教学计划对应的学生 Mapper 接口
 * </p>
 *
 * @author quin.song
 * @since 2023-01-30
 */
@CacheNamespace(implementation = MybatisRedisCache.class, eviction = MybatisRedisCache.class)
public interface PlanTeachingStudentMapper extends BaseMapper<PlanTeachingStudent> {

    int addBatch(@Param("planTeachingStudentCollection") Collection<PlanTeachingStudent> planTeachingStudentCollection);

    /**
     * 获取教学计划主键
     * @param taskId
     * @param baseStudentId
     * @return
     */
    List<Long> getTeachingPlanId(@Param("taskId") Integer taskId, @Param("baseStudentId") String baseStudentId);


    /**
     * 获取学生对应的教学计划
     * @param taskId
     * @param baseStudentId
     * @param studyNature
     * @return
     */
    PlanTeaching getTeachingPlanByStu(@Param("taskId") Integer taskId, @Param("baseStudentId") String baseStudentId, @Param("studyNature") Integer studyNature);

}
